package com.yu.crm.mapper;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yu.crm.domain.pojo.PubUserActionLog;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 用户行为记录表 Mapper 接口
 *
 * @author song
 * @since 2019-11-25
 */
public interface PubUserActionLogMapper extends BaseMapper<PubUserActionLog> {

    IPage<PubUserActionLog> logList(Page<PubUserActionLog> page, @Param(Constants.WRAPPER) QueryWrapper<PubUserActionLog> queryWrapper);

    PubUserActionLog detail(String id);

    List<Map<String, String>> behaviorStatistics();

    List<Map<String, String>> numberVisits(String date);

    Integer userCount();

    Integer ipCount();

    Integer pageCount();

    List<Map<String, Integer>> appCount();
}
